﻿using HelperTool_WHW;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MainFrame
{
   public class LaserControl
    {
        public LaserControl (SocketHelper laseTcp)
        {
            m_socket = laseTcp;
            if(m_socket.Tcp_client.isClientConnected)
            {
                displalyInfo.displayInfoMain("已连接上激光器");
                m_socket.clientReceivedProc += DataRecieve;
            }else
                displalyInfo.displayInfoMain("未连接上激光器" );
        }

        private void DataRecieve(string msg)
        {
            displalyInfo.displayInfoMain("接收到激光器消息:" + msg);
        }

        private SocketHelper m_socket;
        private int SendCmd(string cmd)
        {
            return -1;
        }
    }
}
